if (!(auxframe[cc] = (unsigned char *)malloc(size)))
Error("auxframe[] malloc failed\n");
if(Ersatz_Flag)
if (!(substitute_frame[cc] = (unsigned char *)malloc(size)))
Error("substitute_frame[] malloc failed\n");
if (base.scalable_mode==SC_SPAT)
{
/* this assumes lower layer is 4:2:0 */
if (!(llframe0[cc] = (unsigned char *)malloc((lower_layer_prediction_horizontal_size*lower_layer_prediction_vertical_size)/(cc?4:1))))
Error("llframe0 malloc failed\n");
if (!(llframe1[cc] = (unsigned char *)malloc((lower_layer_prediction_horizontal_size*lower_layer_prediction_vertical_size)/(cc?4:1))))
Error("llframe1 malloc failed\n");
}
}
/* SCALABILITY: Spatial */
if (base.scalable_mode==SC_SPAT)
{
if (!(lltmp = (short *)malloc(lower_layer_prediction_horizontal_size*((lower_layer_prediction_vertical_size*vertical_subsampling_factor_n)/vertical_subsampling_factor_m)*sizeof(short))))